<!--
  @author heguanghua
  @since 2020/04/16 10:11
-->
<!DOCTYPE html SYSTEM "http://www.thymeleaf.org/dtd/xhtml1-strict-thymeleaf-4.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">
<head th:include="common/common::jscss"/>
<body>

<div class="layui-fluid"
     th:with="hasAddEdit=${#authPermit.checkPermit('/sys/modify/addEdit.action')}">

    <blockquote class="layui-crumb">
        <a th:lay-href="|${SYS_MCC}/sys/list.action|">系统管理</a>&nbsp;&nbsp;>&nbsp;
        <zmn th:text="${(obj.sysId eq null) ? '新增系统' : obj.sysName}">新增或修改系统</zmn>
    </blockquote>

    <div class="layui-card">

        <div class="layui-card-body">

            <form method="POST" action="" class="layui-form" lay-filter="zmn-form">

                <input type="hidden" name="sysId" th:value="${obj.sysId}"/>

                <div class="layui-card-header layui-margin-b"><b>基本信息</b></div>

                <div class="layui-form-item" th:if="${obj.sysId > 0}">
                    <label class="layui-form-label">系统ID：</label>
                    <div class="layui-input-block">
                        <div class="layui-form-mid">
                            <span th:text="${obj.sysId}">ID</span>
                        </div>
                    </div>
                </div>
                <div class="layui-form-item">
                    <label class="layui-form-label">系统名称：</label>
                    <div class="layui-input-inline" style="width:300px">
                        <input type="text" name="sysName" th:value="${obj.sysName}" placeholder="系统的名称" lay-verify="required" lay-verType="tips" autocomplete="off" class="layui-input" maxlength="20"/>
                    </div>
                </div>
                <div class="layui-form-item">
                    <label class="layui-form-label">URL：</label>
                    <div class="layui-input-inline" style="width:300px">
                        <input type="text" name="url" th:value="${obj.url}" placeholder="系统BaseUrl" lay-verify="required" lay-verType="tips" autocomplete="off" class="layui-input" maxlength="150"/>
                    </div>
                </div>
                <div class="layui-form-item">
                    <label class="layui-form-label">责任人：</label>
                    <div class="layui-input-inline" style="width:300px">
                        <input type="text" name="owner" th:value="${obj.owner}" placeholder="" lay-verify="" lay-verType="tips" autocomplete="off" class="layui-input" maxlength="150"/>
                    </div>
                </div>

                <div class="layui-form-item">
                    <label class="layui-form-label">备注说明：</label>
                    <div class="layui-input-block" style="width:600px;">
                        <textarea name="remark" th:text="${obj.remark}" class="layui-textarea" placeholder="" lay-verify="" lay-verType="tips"></textarea>
                    </div>
                </div>

                <zmn th:if="${obj.sysId > 0}">
                    <div class="layui-card-header layui-margin-b"><b>其他信息</b></div>

                    <div class="layui-form-item layui-form-item-sm">
                        <label class="layui-form-label">修改人/时间：</label>
                        <div class="layui-input-block">
                            <div class="layui-form-mid layui-word-aux" th:text="${obj.updater} + '&nbsp;/&nbsp;' + ${#dates.format(obj.updateTime, 'yyyy-MM-dd HH:mm:ss')}">修改人/时间</div>
                        </div>
                    </div>
                    <div class="layui-form-item layui-form-item-sm">
                        <label class="layui-form-label">创建人/时间：</label>
                        <div class="layui-input-block">
                            <div class="layui-form-mid layui-word-aux" th:text="${obj.creater} + '&nbsp;/&nbsp;' + ${#dates.format(obj.createTime, 'yyyy-MM-dd HH:mm:ss')}">创建人/时间</div>
                        </div>
                    </div>
                </zmn>

                <div class="layui-form-item submit">
                    <div class="layui-input-block" th:if="${hasAddEdit}">
                        <button class="layui-btn" lay-submit="" lay-filter="zmn-form-submit">保存</button>
                        <button type="reset" class="layui-btn layui-btn-primary">重置</button>
                    </div>
                </div>

            </form>

        </div>

    </div>

</div>
</body>
</html>

<script type="text/javascript" th:inline="javascript">

    layui.extend({
        sys_detail: "sys/zmn.sys.detail",
    }).use(['index', 'sys_detail']);

</script>
